<template>
  <el-table-column fixed="right" align="center" width="180px" label="操作">
    <template slot-scope="scope">
      <el-tooltip class="item" effect="dark" content="修改当前所选列" placement="top" :enterable="false">
        <el-button type="primary" icon="el-icon-edit" size="mini" @click="edit(scope.row)"></el-button>
      </el-tooltip>

      <el-tooltip class="item" effect="dark" content="删除当前所选列" placement="top" :enterable="false">
        <el-button type="danger" icon="el-icon-delete" size="mini" @click="deleteById(scope.row)"></el-button>
      </el-tooltip>
    </template>
  </el-table-column>
</template>

<script>
export default {
  methods: {
    deleteById(row) {
      this.$emit('deleteById', row)
    },
    edit(row) {
      this.$emit('edit', row)
    },
  },
}
</script>

<style></style>
